package com.rc.saas.tenant.mapper.order;

import com.rc.saas.tenant.common.base.BaseMapper;
import com.rc.saas.tenant.model.order.OrderDiscountRecord;
import com.rc.saas.tenant.model.order.OrderDiscountRecordExample;
import com.rc.saas.tenant.search.order.OrderDiscountRecordSearch;
import com.rc.saas.tenant.vo.order.ExportOrderDiscountRecordVo;
import com.rc.saas.tenant.vo.order.OrderDiscountRecordVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface OrderDiscountRecordMapper extends BaseMapper<Long, OrderDiscountRecord, OrderDiscountRecordExample> {

    List<OrderDiscountRecord> orderDiscountRecordList(@Param(value = "count") Integer count);

    /**
     * 优惠列表分页查询
     * @param search
     * @return
     */
    List<OrderDiscountRecordVo> searchByCondition(OrderDiscountRecordSearch search);

    /**
     * 导出优惠列表信息
     * @param search
     * @return
     */
    List<ExportOrderDiscountRecordVo> exportOrderDiscountRecord(OrderDiscountRecordSearch search);

    /**
     * 逻辑删除优惠信息
     * @param orderDiscountId
     * @param loginName
     */
    void delOrderDiscountRecord(@Param(value = "orderDiscountId") Long orderDiscountId, @Param(value = "loginName")String loginName);
}